The present invention relates to digital halftoning of continuous tone images and, more particularly, to a method of error diffusion for digital halftoning.
Digital halftoning is a technique for rendering continuous tone images on display devices that are incapable of producing the number of levels of luminance or chrominance that are contained in the original image. By way of example, digital halftoning is used to print images having continuous gray levels on printers that are only capable of binary output; that is, printing (or not printing) a black dot. Likewise, digital halftoning may be used to display continuous tone color images on displays that are only capable of rendering a limited number of combinations of red, green, and blue.
To render an image with a halftoning process, the colors of the image""s picture elements or pixels are sampled and quantized. The color of a pixel may be represented by the levels of the composite luminance and chrominance signals. The luminance of the pixels of continuous tone gray images is quantized into gray levels for rendering with binary output devices. Typically, gray tones are quantized with 256 levels facilitating description of a pixel by eight data bits. For color displays, the composite luminance and chrominance signals are converted to individual xe2x80x9cred, green, and bluexe2x80x9d signals or xe2x80x9ccyan, magenta, yellow, and blackxe2x80x9d signals as required by digital color output devices.
To print or display an image with halftoning, the image is decomposed into a grid of halftone cells each containing a number of picture elements or pixels. The gray of an area of the original image is simulated by printing or displaying black pixels distributed throughout the halftone cells of the corresponding area of the rendered image. Likewise, colors not included in an output device""s color pallette are simulated by distributing pixels throughout the halftone cell printed or displayed with xe2x80x9cnearbyxe2x80x9d colors available from the pallette. Digital halftoning is effective because of the tendency of the human visual system to ignore fine detail and primarily sense the overall intensity of an area of an image.
One common technique for digital halftoning is error diffusion or spatial dithering. Error diffusion was first disclosed by Floyd and Steinberg in AN ADAPTIVE ALGORITHM FOR SPATIAL GRAYSCALE, Proceedings of the Society for Information Display, vol.17-2, pages 75-77 (1976). In the error diffusion technique the color of each pixel of the original image is measured and quantized. An input color signal representing the measured color of the pixel plus an error diffusion adjustment is compared to a preselected threshold or boundary signal that divides the signals representing the available display colors in the device""s pallette. A display color nearest the original color is selected and the output device is instructed to render the subject pixel in this display color. The error or difference between the adjusted input color signal for the subject pixel and the display color chosen from the pallette is determined. The error is divided according to a weighting function to create a plurality of diffusion adjustment factors. The diffusion adjustment factors are fed back to the input and added to the input color signals for pixels neighboring the first pixel. The adjusted input color signal is, therefore, the measured color value of the pixel plus the accumulated adjustment factors resulting from quantization errors in selecting display colors for neighboring pixels. In other words, the quantization error resulting from selecting a color for a pixel from a limited pallet is diffused over the area neighboring that pixel. The portion of the error distributed to each pixel and the dimensions and shape of the neighborhood over which the error is distributed differ for several specific variants of the error diffusion technique.
While error diffusion is one of the most effective and common techniques for digital halftoning, the signal delay of the process can generate undesirable artifacts in the output image. In highlight and shadow areas, error diffusion can produce xe2x80x9cworms,xe2x80x9d transient noise, and edge delays. In midtone areas, error diffusion can produce unpleasant patterning and pattern shifts. Adding noise to the boundary to randomize the threshold decision or utilizing multiple diffusion filters with varying adjustment factor weighting have been suggested as ways to reduce or eliminate these artifacts. However, these techniques either reduce the quality of the output image or increase the processing delay and often the cost of the halftoning processor.
What is desired, therefore, is a method for error diffusion for halftoning that significantly reduces or eliminates artifacts in the rendered image and which does not adversely impact image quality, the latency of the halftoning process, or unduly complicate the halftoning processor.
The present invention overcomes the aforementioned drawbacks of the prior art by providing a method for selecting an output color for a pixel comprising comparing an input color signal to a boundary separating available output colors; both the input color signal and the boundary being adjusted to reflect, at least in part, an relationship between the output color and the input color signal for another pixel. Adjusting the boundary for the threshold decision makes it possible to neutralize the quantization error produced by application of error diffusion and, thus, eliminate artifacts which are the results of that quantization error. The higher level error diffusion method of the present invention eliminates artifacts in the displayed image without significantly increasing the latency of the error diffusion process or adversely impacting the quality of the image.
The foregoing and other objectives, features and advantages of the invention will be more readily understood upon consideration of the following detailed description of the invention, taken in conjunction with the accompanying drawings.